package com.caltco.cargo.ops.modules.sys.request;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.caltco.cargo.ops.common.annotation.FieldColumn;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonProperty;
import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.NotBlank;
import lombok.Data;
@Data
public class UpdateRequest {

    @TableId(type = IdType.ASSIGN_ID)
    @JsonFormat(shape = JsonFormat.Shape.STRING)
    @Schema(description = "用户Id")
    private Long id;

    @Schema(description = "号码")
    @FieldColumn(name = "号码")
    private String phone;

    @Schema(description = "邮箱")
    @FieldColumn(name = "邮箱")
    private String email;

    @Schema(description = "邮箱验证码")
    @FieldColumn(name = "邮箱验证码")
    private String emailCode;

    @NotBlank(message="用户名不能为空")
    @Schema(description = "用户名")
    @FieldColumn(name = "用户名")
    private String username;

    @Schema(description = "爱好")
    @FieldColumn(name = "爱好")
    private String love;


    @NotBlank(message="密码不能为空")
    @JsonProperty(access = JsonProperty.Access.WRITE_ONLY)
    @Schema(description = "密码")
    private String password;

    @Schema(description = "确认密码")
    private String confirmPassword;

    @Schema(description = "用户头像")
    private String userPhoto;

    @Schema(description = "性别")
    @FieldColumn(name = "性别")
    private Integer sex;

    @Schema(description = "年龄")
    @FieldColumn(name = "年龄")
    private Integer age;

    @Schema(description = "学校")
    @FieldColumn(name = "学校")
    private String school;

    @Schema(description = "简历")
    @FieldColumn(name = "简历")
    private String resume;

}
